package com.cypher.encryptionanddecryption.activity;

import android.app.Activity;

import java.util.ArrayList;
import java.util.List;

/**
 * activity管理单例类
 *
 * @author: 古霸天
 * @date: 2020/11/25
 */
public class ApplicationManager {
    private static List<Activity> activities;
    public List<Activity> getActivities() {
        return activities;
    }
    public void setActivities(List<Activity> activities) {
        this.activities = activities;
    }

    public static ApplicationManager manager = null;
    private ApplicationManager() {

    }

    public static ApplicationManager getInstance() {
        if (manager == null) {
            manager = new ApplicationManager();
        }
        if (activities == null) {
            activities = new ArrayList<Activity>();
        }
        return manager;
    }
}
